package com.terrier.ui.skins.defaults
{
    import com.terrier.ui.skins.WxFlaSkinUtility;
    import com.terrier.ui.skins.WxTextStyle;
    import com.terrier.ui.skins.skinBaseClasses.WxCheckButtonSkinBase;

    import flash.display.DisplayObject;
    import flash.display.Sprite;

    public class WxCheckButtonSkinDefault extends WxCheckButtonSkinBase
    {
        public function WxCheckButtonSkinDefault()
        {
            _upBg = new CheckBox_upIcon();
            _overBg = new CheckBox_overIcon();
            _downBg = new CheckBox_downIcon();
            _disabledBg = new CheckBox_disabledIcon();

            _selectedUpBg = new CheckBox_selectedUpIcon();
            _selectedOverBg = new CheckBox_selectedOverIcon();
            _selectedDownBg = new CheckBox_selectedDownIcon();
            _selectedDisabledBg = new CheckBox_selectedDisabledIcon();

            _upBg.y = _overBg.y = _downBg.y = _disabledBg.y = 5;
            _selectedUpBg.y = _selectedOverBg.y = _selectedDownBg.y = _selectedDisabledBg.y = 5;

            var textAsset:Sprite = new CheckButton_textStyle();
            _upTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 1);
            _overTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 2);
            _downTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 3);
            _disabledTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 4);

            _selectedUpTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 5);
            _selectedOverTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 6);
            _selectedDownTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 7);
            _selectedDisabledTxtStyle = WxFlaSkinUtility.getTextStyle(textAsset, 8);

            _upTxtStyle.customLayout = _overTxtStyle.customLayout = _downTxtStyle.customLayout = _disabledTxtStyle.customLayout = true;
			
			_selectedUpTxtStyle.customLayout = _selectedOverTxtStyle.customLayout = _selectedDownTxtStyle.customLayout = _selectedDisabledTxtStyle.customLayout = true;
        }

        override public function get customLayout():Boolean
        {
            return true;
        }
    }
}
